﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Mono.Cecil;

namespace devtm.Aop.Extensions
{
    
    public static class GenericParameterExt
    {

        public static bool AreEquals(this Mono.Collections.Generic.Collection<GenericParameter> col1, Mono.Collections.Generic.Collection<GenericParameter> col2)
        {

            if (col1.Count != col2.Count)
                return false;

            for (int i = 0; i < col1.Count; i++)
                for (int j = 0; j < col1[i].Constraints.Count; j++)
                    if (col1[i].Constraints[j].ToString() != col2[i].Constraints[j].ToString())
                        return false;

            return true;

        }


    }
}
